﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.ServiceProcess;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using WindowsService.Common;

namespace WindowsService.BusinessServices
{
    public class TaskStart2
    {

        /// <summary>
        /// 业务开始运行
        /// </summary>
        public void TaskProcessing()
        {
            LogHelper.Write("Start", ".....服务正式运行.....");
            Thread.Sleep(1000 * 5 * 1); //在5秒内进行附加进程
            while (true)
            {
                try
                {

                    LogHelper.Write(nameof(Guid), Guid.NewGuid().ToString());
                    Thread.Sleep(1000 * 5 * 1);
                }
                catch { }
            }
        }
    }
}
